home *** CD-ROM | disk | FTP | other *** search
/ PC World 2000 February / PCWorld_2000-02_cd.bin / Software / Vyzkuste / xsetup / _SETUP.2 / Group3 / XQ Shell Folders 2.xpl < prev    next >
Text File  |  1999-09-25  |  3KB  |  83 lines

  1. "FILE"="Xteq Systems X-Setup Plugin 5.0"
  2. "TYPE"="4"
  3. "COUNT"="4"
  4. "UIPATH"="System\File System\Folders: System"
  5. "NAME"="Windows Folders"
  6. "VERSION"="1.13"
  7. "LANGUAGE"="VBScript"
  8. "TEXT 1"="Setup Folder"
  9. "TEXT 2"="Startup Folder"
  10. "TEXT 3"="Cache Folder
  11. "TEXT 4"="Last Known Good"
  12. "DESCRIPTION 1"=""Setup Folder" specifies where the files of your Windows Setup are located."
  13. "DESCRIPTION 2"=""Startup" specifies the folder where all included links and programs are executed when Windows starts."
  14. "DESCRIPTION 3"=""Cache" specifies the folder for TEMP files that should be cached. For example, Internet Explorer uses this folder for its downloaded HTML and image files."
  15. "DESCRIPTION 4"=""Last Known Good" specifies the folder for the "Last known-good" version of some Windows files that are needed by the "System File Checker" (Windows 98/2000)."
  16. "AUTHOR"="Xteq Systems"
  17. "COPYRIGHT"="Copyright ⌐ Xteq Systems - All Rights Reserved"
  18. "COMMENT 1"="For more information, go to http://www.xteq.com or write to TeXHeX@xteq.com."
  19. "COMMENT 2"="Thanks to Pierre Szwarc for his help!"
  20.  
  21.  
  22. bWin95=true
  23. sP1="HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders\"
  24. sP2="HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders\"
  25.  
  26. sV3="HKUS\.DEFAULT\Software\Microsoft\Windows\CurrentVersion\Applets\System File Checker\Src1"
  27. Sub Plugin_Initialize 
  28.  s=RegReadValue("HKLM\Software\Microsoft\Windows\CurrentVersion\Setup\SourcePath")
  29.  if IsEmpty(s) then
  30.     s=RegReadValue("HKLM\Software\Microsoft\Windows NT\CurrentVersion\SourcePath")
  31.     bWin95=false
  32.  end if
  33.  SetUIElement 1,s
  34.  
  35.  
  36.  s=RegReadValue(sP1 & "Startup")
  37.  SetUIElement 2,s
  38.  
  39.  s=RegReadValue(sP1 & "Cache")
  40.  SetUIElement 3,s
  41.  
  42.  s=RegReadValue(sV3)
  43.  SetUIElement 4,s
  44. End Sub
  45.  
  46.  
  47. Sub Plugin_CheckData(ElementIndex)
  48. End Sub
  49.  
  50.  
  51.  
  52. Sub Plugin_Apply(ElementIndex,ElementSubIndex)
  53.  s=GetUIElement(1)
  54.  if bWin95 then
  55.   Call RegWriteValue("HKLM\Software\Microsoft\Windows\CurrentVersion\Setup\SourcePath",s,1)
  56.  else
  57.   Call RegWriteValue("HKLM\Software\Microsoft\Windows NT\CurrentVersion\SourcePath",s,1)
  58.  end if
  59.  
  60.  
  61.  s=GetUIElement(2)
  62.  Call RegWriteValue(sP1 & "Startup",s,1)
  63.  Call RegWriteValue(sP2 & "Startup",s,1)
  64.  
  65.  s=GetUIElement(3)
  66.  Call RegWriteValue(sP1 & "Cache",s,1)
  67.  Call RegWriteValue(sP2 & "Cache",s,1)
  68.  
  69.  
  70.  s=GetUIElement(4)
  71.  Call RegWriteValue(sV3,s,1)
  72.  
  73.  
  74.  Call Restart 'Required because of ActiveDestop and other crap
  75. End Sub
  76.  
  77.  
  78. Sub Plugin_Terminate 
  79. End Sub
  80.  
  81.  
  82.  
  83.